<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.6"/>
<title>SYMMETRY: cPermElem Class Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<script type="text/javascript">
  $(document).ready(initResizable);
  $(window).load(resizeHeight);
</script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/search.js"></script>
<script type="text/javascript">
  $(document).ready(function() { searchBox.OnSelectItem(0); });
</script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td style="padding-left: 0.5em;">
   <div id="projectname">SYMMETRY
   </div>
   <div id="projectbrief">C++LIBRARYFORSCIENTIFICCOMPUTATION</div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.6 -->
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "search",false,'Search');
</script>
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>Main&#160;Page</span></a></li>
      <li class="current"><a href="annotated.html"><span>Classes</span></a></li>
      <li><a href="files.html"><span>Files</span></a></li>
      <li>
        <div id="MSearchBox" class="MSearchBoxInactive">
        <span class="left">
          <img id="MSearchSelect" src="search/mag_sel.png"
               onmouseover="return searchBox.OnSearchSelectShow()"
               onmouseout="return searchBox.OnSearchSelectHide()"
               alt=""/>
          <input type="text" id="MSearchField" value="Search" accesskey="S"
               onfocus="searchBox.OnSearchFieldFocus(true)" 
               onblur="searchBox.OnSearchFieldFocus(false)" 
               onkeyup="searchBox.OnSearchFieldChange(event)"/>
          </span><span class="right">
            <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.png" alt=""/></a>
          </span>
        </div>
      </li>
    </ul>
  </div>
  <div id="navrow2" class="tabs2">
    <ul class="tablist">
      <li><a href="annotated.html"><span>Class&#160;List</span></a></li>
      <li><a href="classes.html"><span>Class&#160;Index</span></a></li>
      <li><a href="inherits.html"><span>Class&#160;Hierarchy</span></a></li>
      <li><a href="functions.html"><span>Class&#160;Members</span></a></li>
    </ul>
  </div>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
  <div id="nav-tree">
    <div id="nav-tree-contents">
      <div id="nav-sync" class="sync"></div>
    </div>
  </div>
  <div id="splitbar" style="-moz-user-select:none;" 
       class="ui-resizable-handle">
  </div>
</div>
<script type="text/javascript">
$(document).ready(function(){initNavTree('classcPermElem.html','');});
</script>
<div id="doc-content">
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
<a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(0)"><span class="SelectionMark">&#160;</span>All</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(1)"><span class="SelectionMark">&#160;</span>Classes</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(2)"><span class="SelectionMark">&#160;</span>Functions</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(3)"><span class="SelectionMark">&#160;</span>Pages</a></div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div class="header">
  <div class="summary">
<a href="#pub-methods">Public Member Functions</a> &#124;
<a href="#pri-methods">Private Member Functions</a> &#124;
<a href="#pri-attribs">Private Attributes</a> &#124;
<a href="#friends">Friends</a> &#124;
<a href="classcPermElem-members.html">List of all members</a>  </div>
  <div class="headertitle">
<div class="title">cPermElem Class Reference</div>  </div>
</div><!--header-->
<div class="contents">

<p><code>#include &lt;<a class="el" href="permutation_8h_source.html">permutation.h</a>&gt;</code></p>
<div class="dynheader">
Collaboration diagram for cPermElem:</div>
<div class="dyncontent">
<div class="center"><img src="classcPermElem__coll__graph.png" border="0" usemap="#cPermElem_coll__map" alt="Collaboration graph"/></div>
<map name="cPermElem_coll__map" id="cPermElem_coll__map">
<area shape="rect" id="node3" title="STL class. " alt="" coords="34,147,152,224"/></map>
</div>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-methods"></a>
Public Member Functions</h2></td></tr>
<tr class="memitem:a9170fa558dd3cdfae7879631db41235d"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classcPermElem.html#a9170fa558dd3cdfae7879631db41235d">cPermElem</a> ()</td></tr>
<tr class="separator:a9170fa558dd3cdfae7879631db41235d"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ad3ff2e93580acca710249f0eb7e04bc3"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classcPermElem.html#ad3ff2e93580acca710249f0eb7e04bc3">cPermElem</a> (std::size_t size)</td></tr>
<tr class="separator:ad3ff2e93580acca710249f0eb7e04bc3"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a375e3da4877dd48e93ca192bfcd66ddd"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classcPermElem.html#a375e3da4877dd48e93ca192bfcd66ddd">cPermElem</a> (std::size_t size, const std::initializer_list&lt; std::size_t &gt; &amp;perm_sq)</td></tr>
<tr class="separator:a375e3da4877dd48e93ca192bfcd66ddd"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a88b976442227c8da9ede9cf9d3f865c5"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classcPermElem.html#a88b976442227c8da9ede9cf9d3f865c5">cPermElem</a> (const std::initializer_list&lt; std::size_t &gt; &amp;perm_sq)</td></tr>
<tr class="separator:a88b976442227c8da9ede9cf9d3f865c5"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a05895c11888d83bc3d35b3c18d90e8e4"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classcPermElem.html#a05895c11888d83bc3d35b3c18d90e8e4">cPermElem</a> (std::vector&lt; std::size_t &gt; &amp;perm_sq)</td></tr>
<tr class="separator:a05895c11888d83bc3d35b3c18d90e8e4"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a1b5d12f8fb6131643253f5ed3bad6c28"><td class="memItemLeft" align="right" valign="top">const std::vector&lt; std::size_t &gt; &amp;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classcPermElem.html#a1b5d12f8fb6131643253f5ed3bad6c28">GetPermutationArray</a> () const </td></tr>
<tr class="separator:a1b5d12f8fb6131643253f5ed3bad6c28"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a19da6e521f8adf3d252250f3836c563e"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classcPermElem.html">cPermElem</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classcPermElem.html#a19da6e521f8adf3d252250f3836c563e">operator*</a> (const <a class="el" href="classcPermElem.html">cPermElem</a> &amp;perm) const </td></tr>
<tr class="separator:a19da6e521f8adf3d252250f3836c563e"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a925aac2e4ac73ec288b7a1e16b941d40"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a925aac2e4ac73ec288b7a1e16b941d40"></a>
bool&#160;</td><td class="memItemRight" valign="bottom"><b>operator==</b> (const <a class="el" href="classcPermElem.html">cPermElem</a> &amp;perm) const </td></tr>
<tr class="separator:a925aac2e4ac73ec288b7a1e16b941d40"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a925cdee12dcc4914417143a88d91c49d"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a925cdee12dcc4914417143a88d91c49d"></a>
bool&#160;</td><td class="memItemRight" valign="bottom"><b>operator!=</b> (const <a class="el" href="classcPermElem.html">cPermElem</a> &amp;perm) const </td></tr>
<tr class="separator:a925cdee12dcc4914417143a88d91c49d"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:afa5694d1831e653f4cc3b12de6bb058e"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classcPermElem.html#afa5694d1831e653f4cc3b12de6bb058e">rotateLeft</a> ()</td></tr>
<tr class="separator:afa5694d1831e653f4cc3b12de6bb058e"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:adad3b042383cf3538bfec790188987c3"><td class="memItemLeft" align="right" valign="top">std::size_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classcPermElem.html#adad3b042383cf3538bfec790188987c3">GetImage</a> (const std::size_t set_element) const </td></tr>
<tr class="separator:adad3b042383cf3538bfec790188987c3"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:adbb23b8a368e0d01cd2b450ad0be5efb"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classcPermElem.html">cPermElem</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classcPermElem.html#adbb23b8a368e0d01cd2b450ad0be5efb">GetMultInverse</a> () const </td></tr>
<tr class="separator:adbb23b8a368e0d01cd2b450ad0be5efb"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a11cc987f70282d2984c04c6e058c41e8"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classcPermElem.html">cPermElem</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classcPermElem.html#a11cc987f70282d2984c04c6e058c41e8">GetAdInverse</a> () const </td></tr>
<tr class="separator:a11cc987f70282d2984c04c6e058c41e8"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a773fc9acee08d4c86d391439574eaf3e"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a773fc9acee08d4c86d391439574eaf3e"></a>
std::size_t&#160;</td><td class="memItemRight" valign="bottom"><b>GetSize</b> () const </td></tr>
<tr class="separator:a773fc9acee08d4c86d391439574eaf3e"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a7f5392e3279b766d5f85c01d363c2941"><td class="memTemplParams" colspan="2">template&lt;typename BINOP &gt; </td></tr>
<tr class="memitem:a7f5392e3279b766d5f85c01d363c2941"><td class="memTemplItemLeft" align="right" valign="top"><a class="el" href="classcPermElem.html">cPermElem</a>&#160;</td><td class="memTemplItemRight" valign="bottom"><a class="el" href="classcPermElem.html#a7f5392e3279b766d5f85c01d363c2941">GetIdentity</a> (BINOP binop) const </td></tr>
<tr class="separator:a7f5392e3279b766d5f85c01d363c2941"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a06f75de000ad4b9524116a029800ca26"><td class="memItemLeft" align="right" valign="top">std::size_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classcPermElem.html#a06f75de000ad4b9524116a029800ca26">GetInversions</a> () const </td></tr>
<tr class="separator:a06f75de000ad4b9524116a029800ca26"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pri-methods"></a>
Private Member Functions</h2></td></tr>
<tr class="memitem:abefedad75d8175a886b30a6d36a0eb98"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classcPermElem.html#abefedad75d8175a886b30a6d36a0eb98">CountInversions</a> (std::vector&lt; std::size_t &gt;::iterator begin, std::vector&lt; std::size_t &gt;::iterator end, std::size_t &amp;inversions) const </td></tr>
<tr class="separator:abefedad75d8175a886b30a6d36a0eb98"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aa39ae9f1b4d3efd38616ff822caebbb9"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classcPermElem.html#aa39ae9f1b4d3efd38616ff822caebbb9">MergeInversions</a> (std::vector&lt; std::size_t &gt;::iterator begin, std::vector&lt; std::size_t &gt;::iterator begin_right, std::vector&lt; std::size_t &gt;::iterator end, std::size_t &amp;inversions) const </td></tr>
<tr class="separator:aa39ae9f1b4d3efd38616ff822caebbb9"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pri-attribs"></a>
Private Attributes</h2></td></tr>
<tr class="memitem:a9a8f181852cd76a706631b5283342c7f"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a9a8f181852cd76a706631b5283342c7f"></a>
std::vector&lt; std::size_t &gt;&#160;</td><td class="memItemRight" valign="bottom"><b>m_PermArray</b></td></tr>
<tr class="separator:a9a8f181852cd76a706631b5283342c7f"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="friends"></a>
Friends</h2></td></tr>
<tr class="memitem:a4211aa547f8e3f2dc6b44ad07f7224db"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a4211aa547f8e3f2dc6b44ad07f7224db"></a>
std::ostream &amp;&#160;</td><td class="memItemRight" valign="bottom"><b>operator&lt;&lt;</b> (std::ostream &amp;of, const <a class="el" href="classcPermElem.html">cPermElem</a> &amp;perm)</td></tr>
<tr class="separator:a4211aa547f8e3f2dc6b44ad07f7224db"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
<div class="textblock"><p>class representing a permutation (element) permutation is represented internally using an array of ints </p>
</div><h2 class="groupheader">Constructor &amp; Destructor Documentation</h2>
<a class="anchor" id="a9170fa558dd3cdfae7879631db41235d"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">cPermElem::cPermElem </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>default constructor for empty permutation </p>

</div>
</div>
<a class="anchor" id="ad3ff2e93580acca710249f0eb7e04bc3"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">cPermElem::cPermElem </td>
          <td>(</td>
          <td class="paramtype">std::size_t&#160;</td>
          <td class="paramname"><em>size</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>constructor for identity permutation </p>

</div>
</div>
<a class="anchor" id="a375e3da4877dd48e93ca192bfcd66ddd"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">cPermElem::cPermElem </td>
          <td>(</td>
          <td class="paramtype">std::size_t&#160;</td>
          <td class="paramname"><em>size</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const std::initializer_list&lt; std::size_t &gt; &amp;&#160;</td>
          <td class="paramname"><em>perm_sq</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>constructor for permutation given as a cycle using initializer_list ie. (3,{1,3,2}) means 1-&gt;3 3-&gt;2 2-&gt;1 </p>

</div>
</div>
<a class="anchor" id="a88b976442227c8da9ede9cf9d3f865c5"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">cPermElem::cPermElem </td>
          <td>(</td>
          <td class="paramtype">const std::initializer_list&lt; std::size_t &gt; &amp;&#160;</td>
          <td class="paramname"><em>perm_sq</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>constructor for permutation given as an image using initializer_list ie. {2,3,1} means 1-&gt;2 2-&gt;3 3-&gt;1 </p>

</div>
</div>
<a class="anchor" id="a05895c11888d83bc3d35b3c18d90e8e4"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">cPermElem::cPermElem </td>
          <td>(</td>
          <td class="paramtype">std::vector&lt; std::size_t &gt; &amp;&#160;</td>
          <td class="paramname"><em>perm_sq</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>constructor for permutation given as an image using a vector ie. vector a = {2,3,1} is the permutation 1-&gt;2 2-&gt;3 3-&gt;1 </p>

</div>
</div>
<h2 class="groupheader">Member Function Documentation</h2>
<a class="anchor" id="abefedad75d8175a886b30a6d36a0eb98"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">void cPermElem::CountInversions </td>
          <td>(</td>
          <td class="paramtype">std::vector&lt; std::size_t &gt;::iterator&#160;</td>
          <td class="paramname"><em>begin</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">std::vector&lt; std::size_t &gt;::iterator&#160;</td>
          <td class="paramname"><em>end</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">std::size_t &amp;&#160;</td>
          <td class="paramname"><em>inversions</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td> const</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">private</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>helper function for GetInversions &ndash; modified merge sort Complexity: O(nlgn) </p>

<p><div class="dynheader">
Here is the call graph for this function:</div>
<div class="dyncontent">
<div class="center"><img src="classcPermElem_abefedad75d8175a886b30a6d36a0eb98_cgraph.png" border="0" usemap="#classcPermElem_abefedad75d8175a886b30a6d36a0eb98_cgraph" alt=""/></div>
<map name="classcPermElem_abefedad75d8175a886b30a6d36a0eb98_cgraph" id="classcPermElem_abefedad75d8175a886b30a6d36a0eb98_cgraph">
<area shape="rect" id="node2" href="classcPermElem.html#aa39ae9f1b4d3efd38616ff822caebbb9" title="cPermElem::MergeInversions" alt="" coords="256,5,461,32"/></map>
</div>
</p>

</div>
</div>
<a class="anchor" id="a11cc987f70282d2984c04c6e058c41e8"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classcPermElem.html">cPermElem</a> cPermElem::GetAdInverse </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td> const</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>the same as GetMultInverse &ndash; defined for consistency </p>

<p><div class="dynheader">
Here is the call graph for this function:</div>
<div class="dyncontent">
<div class="center"><img src="classcPermElem_a11cc987f70282d2984c04c6e058c41e8_cgraph.png" border="0" usemap="#classcPermElem_a11cc987f70282d2984c04c6e058c41e8_cgraph" alt=""/></div>
<map name="classcPermElem_a11cc987f70282d2984c04c6e058c41e8_cgraph" id="classcPermElem_a11cc987f70282d2984c04c6e058c41e8_cgraph">
<area shape="rect" id="node2" href="classcPermElem.html#adbb23b8a368e0d01cd2b450ad0be5efb" title="cPermElem::GetMultInverse" alt="" coords="240,5,435,32"/><area shape="rect" id="node3" href="classcPermElem.html#a9170fa558dd3cdfae7879631db41235d" title="cPermElem::cPermElem" alt="" coords="483,5,653,32"/></map>
</div>
</p>

</div>
</div>
<a class="anchor" id="a7f5392e3279b766d5f85c01d363c2941"></a>
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename BINOP &gt; </div>
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classcPermElem.html">cPermElem</a> cPermElem::GetIdentity </td>
          <td>(</td>
          <td class="paramtype">BINOP&#160;</td>
          <td class="paramname"><em>binop</em></td><td>)</td>
          <td> const</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>returns the identity permutation with the same size as the current permutation </p>

<p><div class="dynheader">
Here is the call graph for this function:</div>
<div class="dyncontent">
<div class="center"><img src="classcPermElem_a7f5392e3279b766d5f85c01d363c2941_cgraph.png" border="0" usemap="#classcPermElem_a7f5392e3279b766d5f85c01d363c2941_cgraph" alt=""/></div>
<map name="classcPermElem_a7f5392e3279b766d5f85c01d363c2941_cgraph" id="classcPermElem_a7f5392e3279b766d5f85c01d363c2941_cgraph">
<area shape="rect" id="node2" href="classcPermElem.html#a9170fa558dd3cdfae7879631db41235d" title="cPermElem::cPermElem" alt="" coords="221,5,392,32"/></map>
</div>
</p>

</div>
</div>
<a class="anchor" id="adad3b042383cf3538bfec790188987c3"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">std::size_t cPermElem::GetImage </td>
          <td>(</td>
          <td class="paramtype">const std::size_t&#160;</td>
          <td class="paramname"><em>set_element</em></td><td>)</td>
          <td> const</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>get the image of an element under the action of the permution </p>

</div>
</div>
<a class="anchor" id="a06f75de000ad4b9524116a029800ca26"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">std::size_t cPermElem::GetInversions </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td> const</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>returns the number of inverses: "inverse" if i &lt; j and A[i] &gt; A[j] modified merge sort =&gt; Complexity: O(nlgn) see Cormen chapter 2 - exercises </p>

<p><div class="dynheader">
Here is the call graph for this function:</div>
<div class="dyncontent">
<div class="center"><img src="classcPermElem_a06f75de000ad4b9524116a029800ca26_cgraph.png" border="0" usemap="#classcPermElem_a06f75de000ad4b9524116a029800ca26_cgraph" alt=""/></div>
<map name="classcPermElem_a06f75de000ad4b9524116a029800ca26_cgraph" id="classcPermElem_a06f75de000ad4b9524116a029800ca26_cgraph">
<area shape="rect" id="node2" href="classcPermElem.html#abefedad75d8175a886b30a6d36a0eb98" title="cPermElem::CountInversions" alt="" coords="241,5,442,32"/><area shape="rect" id="node3" href="classcPermElem.html#aa39ae9f1b4d3efd38616ff822caebbb9" title="cPermElem::MergeInversions" alt="" coords="491,5,696,32"/></map>
</div>
</p>

</div>
</div>
<a class="anchor" id="adbb23b8a368e0d01cd2b450ad0be5efb"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classcPermElem.html">cPermElem</a> cPermElem::GetMultInverse </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td> const</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>returns the permutation inverse Complexity: O(n) </p>

<p><div class="dynheader">
Here is the call graph for this function:</div>
<div class="dyncontent">
<div class="center"><img src="classcPermElem_adbb23b8a368e0d01cd2b450ad0be5efb_cgraph.png" border="0" usemap="#classcPermElem_adbb23b8a368e0d01cd2b450ad0be5efb_cgraph" alt=""/></div>
<map name="classcPermElem_adbb23b8a368e0d01cd2b450ad0be5efb_cgraph" id="classcPermElem_adbb23b8a368e0d01cd2b450ad0be5efb_cgraph">
<area shape="rect" id="node2" href="classcPermElem.html#a9170fa558dd3cdfae7879631db41235d" title="cPermElem::cPermElem" alt="" coords="248,5,419,32"/></map>
</div>
</p>

</div>
</div>
<a class="anchor" id="a1b5d12f8fb6131643253f5ed3bad6c28"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">const std::vector&lt;std::size_t&gt;&amp; cPermElem::GetPermutationArray </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td> const</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>get the underlying permutation array </p>

</div>
</div>
<a class="anchor" id="aa39ae9f1b4d3efd38616ff822caebbb9"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">void cPermElem::MergeInversions </td>
          <td>(</td>
          <td class="paramtype">std::vector&lt; std::size_t &gt;::iterator&#160;</td>
          <td class="paramname"><em>begin</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">std::vector&lt; std::size_t &gt;::iterator&#160;</td>
          <td class="paramname"><em>begin_right</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">std::vector&lt; std::size_t &gt;::iterator&#160;</td>
          <td class="paramname"><em>end</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">std::size_t &amp;&#160;</td>
          <td class="paramname"><em>inversions</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td> const</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">private</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>equivalent to merge procedure from merge sort Complexity: O(n) </p>

</div>
</div>
<a class="anchor" id="a19da6e521f8adf3d252250f3836c563e"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classcPermElem.html">cPermElem</a> cPermElem::operator* </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="classcPermElem.html">cPermElem</a> &amp;&#160;</td>
          <td class="paramname"><em>perm</em></td><td>)</td>
          <td> const</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>permutation mutiplication operator (doesn't work in the true mathematical meaning of composition&ndash; aplies the first permutation first: A*B(x) -&gt; B(A(x)) ) Complexity: O(n) </p>

<p><div class="dynheader">
Here is the call graph for this function:</div>
<div class="dyncontent">
<div class="center"><img src="classcPermElem_a19da6e521f8adf3d252250f3836c563e_cgraph.png" border="0" usemap="#classcPermElem_a19da6e521f8adf3d252250f3836c563e_cgraph" alt=""/></div>
<map name="classcPermElem_a19da6e521f8adf3d252250f3836c563e_cgraph" id="classcPermElem_a19da6e521f8adf3d252250f3836c563e_cgraph">
<area shape="rect" id="node2" href="classcPermElem.html#a9170fa558dd3cdfae7879631db41235d" title="cPermElem::cPermElem" alt="" coords="213,5,384,32"/></map>
</div>
</p>

</div>
</div>
<a class="anchor" id="afa5694d1831e653f4cc3b12de6bb058e"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">void cPermElem::rotateLeft </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p>rotate the elements of the array to the left represents a rotation of the regular polygon with n(size) sides !!!used to compute the cyclic and dihedral group </p>

</div>
</div>
<hr/>The documentation for this class was generated from the following file:<ul>
<li><a class="el" href="permutation_8h_source.html">permutation.h</a></li>
</ul>
</div><!-- contents -->
</div><!-- doc-content -->
<!-- start footer part -->
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
  <ul>
    <li class="navelem"><a class="el" href="classcPermElem.html">cPermElem</a></li>
    <li class="footer">Generated on Tue Feb 25 2014 17:11:52 for SYMMETRY by
    <a href="http://www.doxygen.org/index.html">
    <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.8.6 </li>
  </ul>
</div>
</body>
</html>
